<%@page pageEncoding="UTF-8" isELIgnored="false"%>
<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt"%>
<%@taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions"%>
<%@taglib prefix="f" uri="http://www.slim3.org/functions"%>
<c:import url="/layout.jsp">
<c:param name="title" value="blobstore Index"/>
<c:param name="content">
<script type="text/javascript" src="this.js"></script>

<form action="${f:blobstoreUrl('upload')}" method="post" enctype="multipart/form-data">
<input type="file" name="formFile" /><br />
<input type="submit" value="Upload"/>
</form>
<table>
<c:if test="${fn:length(dataList) > 0}">
<thead>
<tr><th>Key</th></tr>
</thead>
</c:if>
<tbody>
<c:forEach var="e" items="${dataList}">
<tr>
<td>${f:h(e.key.name)}</td>
<c:set var="showUrl" value="show?keyName=${f:h(e.key.name)}"/>
<c:set var="deleteUrl" value="delete?keyName=${f:h(e.key.name)}"/>
<td><a href="${f:url(showUrl)}">Show</a></td>
<td><a href="${f:url(deleteUrl)}" onclick="return confirm('delete OK?')">Delete</a></td>
</tr>
</c:forEach>
</tbody>
</table>
</c:param>
</c:import>
